package com.yidi.system.service;

import com.yidi.common.core.domain.entity.SysUser;
import com.yidi.common.core.page.MyPage;
import com.yidi.common.core.service.BaseService;

import java.util.List;

/**
 * @author ：Xn
 * @ClassName: SysUserService
 * @date ：2021-10-19 14:39
 * @describe ：
 */
public interface SysUserService extends BaseService<SysUser> {

    MyPage<SysUser> selectUserList( SysUser user, Integer pageNo, Integer pageSize);

    SysUser selectUserByUserName(String userName);

    MyPage<SysUser> selectAllocatedList(SysUser user, Integer pageNum,Integer pageSize);

    MyPage<SysUser> selectUnallocatedList(SysUser user, Integer pageNum,Integer pageSize);

    String importUser(List<SysUser> userList, Boolean isUpdateSupport, String operName);

    void checkUserDataScope(Long userId);

    String checkUserNameUnique(String userName);

    String checkPhoneUnique(SysUser user);

    String checkEmailUnique(SysUser user);

    String selectUserRoleGroup(String userName);

    String selectUserPostGroup(String userName);

    void checkUserAllowed(SysUser user);

    void insertUser(SysUser user);

    void updateUser(SysUser user);

    void deleteUserByIds(Long[] userIds);

    void resetPwd(SysUser sysUser);

    void resetUserPwd(String userName, String password);

    void updateUserStatus(SysUser sysUser);

    void updateUserAvatar(String userName, String avatar);

    void insertUserAuth(Long userId, Long[] roleIds);

    void updateUserProfile(SysUser sysUser);

    void updateUserLoginIp(SysUser sysUser);

    boolean registerUser(SysUser user);

}
